/**
 * 
 */
package com.feib.soeasy.job.service;

import java.util.Date;
import java.util.List;

import org.springframework.transaction.annotation.Transactional;

import com.feib.soeasy.model.CodeTable;
import com.feib.soeasy.model.MailQueue;

/**
 * @author Jimmy Liu
 *
 */

@Transactional(readOnly = true)
public interface AutoUploadCarLoanFileService {

	@Transactional(readOnly = false)
	public void updateRunDate(CodeTable runDate);

	@Deprecated
	public List<CodeTable> findCodeTables(String codeKind);

	public CodeTable getCodeTable(String codeKind, String codeValue);

	/**
	 * 下載檔案
	 * @param host FTP SERVER IP
	 * @param port FTP SERVER PORT
	 * @param username FTP 帳號
	 * @param password FTP 密碼
	 * @param localFolder 本地端目錄/下載存放目錄
	 * @param remoteFolder FTP 目錄
	 * @param sFileName 檔案名稱
	 * @param iRetryCnt FTP Retry 次數/下載嘗試數次
	 * @return
	 */
	public boolean retryGetFtpFile(String host, int port, String username, String password,
			String localFolder, String remoteFolder, String sFileName,
			int iRetryCnt);

	public boolean hasUploadFile(String groupNo, String sFileName);

	/**
	 * 是否為假日
	 * @param now
	 * @return
	 */
	public boolean isHoliday(Date now);

	public MailQueue addMailQueue(MailQueue mailQueue);

}
